/** 病害相关的数据库初始化 */
import {
	TAB_DISEASECONTENT
} from "../config";

/** 初始化内容表 */
export const createDiseaseContentTable = db => {
	const sql = `
		create table if not exists '${TAB_DISEASECONTENT}'(
			_id varchar(255),
			id int primary key,
			pid int,
			code varchar(255),
			createUserId int,
			createUserName varchar(255),
			diseaseGrade varchar(255),
			diseaseGradeId int,
			diseaseNo varchar(255),
			diseaseStatus varchar(255),
			leaf int,
			parentId int,
			recordCreateDate varchar(255),
			recordUpdateDate varchar(255),
			treeId varchar(255),
			diseaseCode varchar(255),
			treeLevel int
		);
	`;
	return db.execute(sql);
}
